﻿using System.Collections;
using SailHero.Soft.FrameWork.DAO.Contracts;
using SailHero.Soft.FrameWork.Models;

namespace SailHero.Soft.FrameWork.IDomainRepositories.Contracts
{
    public interface IRoleRepository : IRepository<SYS_ROLE>
    {
        /// <summary>
        /// 设置角色
        /// 先删除当前角色下所有的用户
        /// 然后再添加选中的用户
        /// </summary>
        /// <param name="userID"></param>
        /// <param name="roleID"></param>
        /// <returns></returns>
        string SetUserRole(string userID, string roleID);


        /// <summary>
        /// 查询某一角色下面所有权限
        /// </summary>
        /// <param name="roleID"></param>
        /// <returns></returns>
        IList GetPermissionListByRole(string roleID);


        string SetPermission(string roleID, string parentID, string subID);

    }
}